﻿<ResourceDictionary
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero">
	<!-- Resource dictionary entries should be defined here. -->
	 
	<LinearGradientBrush x:Key="ListViewBackground" EndPoint="0,1" StartPoint="0,0">
		<GradientStop Color="#626262" Offset="1"/>
		<GradientStop Color="#4c4c4c" Offset="0"/>
	</LinearGradientBrush>
	 
	 
    <SolidColorBrush x:Key="ListViewBorder" Color="#7a7a7a" />
    <SolidColorBrush x:Key="ListViewHeaderForeground" Color="White" />
	<SolidColorBrush x:Key="ListViewItemForeground" Color="White" />

    <LinearGradientBrush x:Key="ListViewHeaderBackground" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#6c6a6b" Offset="0"/>
		<GradientStop Color="#282828" Offset="1"/>
    </LinearGradientBrush>	
	
    <LinearGradientBrush x:Key="ListViewHeaderHover" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#6c6a6b" Offset="1"/>
		<GradientStop Color="#282828" Offset="0"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ListViewHeaderPressed" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#d22828" Offset="0"/>
		<GradientStop Color="#b00000" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ListViewItemHover" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#da5e69" Offset="0"/>
		<GradientStop Color="#d12e27" Offset="1"/>
    </LinearGradientBrush>
    
    
    <LinearGradientBrush x:Key="ListViewTopHeaderBackground" StartPoint="0,0" EndPoint="0,1">
        <GradientBrush.GradientStops>
            <GradientStopCollection>
                <GradientStop Color="#adc3dc" Offset="0.0"/>
                <GradientStop Color="#c3ddff" Offset="1.0"/>
            </GradientStopCollection>
        </GradientBrush.GradientStops>
    </LinearGradientBrush>

	<LinearGradientBrush x:Key="ListViewItemSelected" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="#d22828" Offset="1"/>
		<GradientStop Color="#b00000" Offset="0"/>
    </LinearGradientBrush>

    <Style x:Key="{x:Type ListView}" TargetType="ListView">
        <Setter Property="SnapsToDevicePixels" Value="true"/>
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Height" Value="95"/>
        <Setter Property="Width" Value="Auto"/>
        <Setter Property="Margin" Value="5"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListView">
                    <Border Name="Border"
            BorderThickness="1"
            BorderBrush="{StaticResource ListViewBorder}"
            Background="{StaticResource ListViewBackground}" CornerRadius="4">
                        <ScrollViewer Style="{DynamicResource
                          {x:Static GridView.GridViewScrollViewerStyleKey}}">
                            <ItemsPresenter Margin="-2" />
                        </ScrollViewer>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsGrouping"
                     Value="true">
                            <Setter Property="ScrollViewer.CanContentScroll"
                      Value="false"/>
                        </Trigger>
                        <Trigger Property="IsEnabled"
                     Value="false">
                            <Setter TargetName="Border"
                      Property="Background"
                      Value="{StaticResource ListViewBorder}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    <Style x:Key="ListViewInGroupBox" TargetType="ListView">
        <Setter Property="SnapsToDevicePixels" Value="true"/>
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Height" Value="95"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListView">
                    <Border Name="Border"
            BorderThickness="0"
            BorderBrush="{StaticResource ListViewBorder}"
                            CornerRadius="0,0,3,3"
            Background="{StaticResource ListViewBackground}">
                        <ScrollViewer Style="{DynamicResource
                          {x:Static GridView.GridViewScrollViewerStyleKey}}">
                            <ItemsPresenter Margin="0,0,0,0" />
                        </ScrollViewer>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsGrouping"
                     Value="true">
                            <Setter Property="ScrollViewer.CanContentScroll"
                      Value="false"/>
                        </Trigger>
                        <Trigger Property="IsEnabled"
                     Value="false">
                            <Setter TargetName="Border"
                      Property="Background"
                      Value="{StaticResource ListViewBorder}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    <Style x:Key="ListViewTopHeader" TargetType="ListView">
        <Setter Property="SnapsToDevicePixels" Value="true"/>
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Height" Value="96"/>
        <Setter Property="Margin" Value="10,10,5,5"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListView">
                    <Border Name="OuterBorder" BorderThickness="1" BorderBrush="#596991" CornerRadius="3">
                        <Border Name="Border" BorderThickness="1" BorderBrush="White" CornerRadius="2"
            Background="{StaticResource ListViewTopHeaderBackground}">
                            <ScrollViewer Style="{DynamicResource {x:Static GridView.GridViewScrollViewerStyleKey}}">
                                <ItemsPresenter Margin="0,0,0,0" />
                            </ScrollViewer>
                        </Border>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsGrouping"
                     Value="true">
                            <Setter Property="ScrollViewer.CanContentScroll"
                      Value="false"/>
                        </Trigger>
                        <Trigger Property="IsEnabled"
                     Value="false">
                            <Setter TargetName="Border"
                      Property="Background"
                      Value="{StaticResource ListViewBorder}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="GridViewColumnHeaderGripper" TargetType="Thumb">
        <Setter Property="Width" Value="18"/>
        <Setter Property="Visibility" Value="Collapsed"/>
        <Setter Property="Background" Value="{StaticResource ListViewBorder}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Thumb}">
                    <Border Padding="{TemplateBinding Padding}"
            Background="Transparent">
                        <Rectangle HorizontalAlignment="Center"
              Width="1"
              Fill="{TemplateBinding Background}"/>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="{x:Type GridViewColumnHeader}" TargetType="GridViewColumnHeader">
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Foreground" Value="{StaticResource ListViewHeaderForeground}"/>
        <Setter Property="MinHeight" Value="18"/>
        <Setter Property="Height" Value="Auto"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="GridViewColumnHeader">
                    <Grid>
                        <Border Name="HeaderBorder"
              BorderThickness="0,0,1,0"
              BorderBrush="{StaticResource ListViewBorder}"
              Background="{StaticResource ListViewHeaderBackground}"
			  Margin="0"
              Padding="5,2,5,2">
                            <ContentPresenter Name="HeaderContent"
                Margin="0,0,0,0"
                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                RecognizesAccessKey="True"
                SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
                        </Border>
                        <Thumb x:Name="PART_HeaderGripper"
              HorizontalAlignment="Right"
              Margin="0,0,-9,0"
              Style="{StaticResource GridViewColumnHeaderGripper}"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter TargetName="HeaderBorder"
                      Property="Background" Value="{StaticResource ListViewHeaderHover}"/>
                        </Trigger>
                        <Trigger Property="IsPressed" Value="true">
                            <Setter TargetName="HeaderBorder"
                      Property="Background" Value="{StaticResource ListViewHeaderPressed}"/>
                            <Setter TargetName="HeaderContent"
                      Property="Margin" Value="1,1,0,0"/>
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="false">
                            <Setter Property="Foreground"
                      Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Style.Triggers>
            <Trigger Property="Role" Value="Floating">
                <Setter Property="Opacity" Value="0.7"/>
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="GridViewColumnHeader">
                            <Canvas Name="PART_FloatingHeaderCanvas">
                                <Rectangle Fill="#60000000"
                  Width="{TemplateBinding ActualWidth}"
                  Height="{TemplateBinding ActualHeight}"/>
                            </Canvas>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Trigger>
            <Trigger Property="Role" Value="Padding">
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="GridViewColumnHeader">
                            <Border Name="HeaderBorder"
                BorderThickness="0"
                Background="{StaticResource ListViewHeaderBackground}"/>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Trigger>
        </Style.Triggers>
    </Style>
    
    <Style x:Key="{x:Type ListViewItem}" TargetType="ListViewItem">
        <Setter Property="SnapsToDevicePixels" Value="true"/>
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="FontSize" Value="10"/>
        <Setter Property="Height" Value="Auto"/>
        <Setter Property="Foreground" Value="{StaticResource ListViewItemForeground}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListViewItem">
                    <Border 
            Name="Border"
            Padding="2"
            SnapsToDevicePixels="true"
            Background="Transparent" BorderBrush="{StaticResource ListViewBorder}" BorderThickness="0,1,0,0">
                        <GridViewRowPresenter
              VerticalAlignment="{TemplateBinding VerticalContentAlignment}" OpacityMask="{x:Null}" Margin="0,0,0,0"/>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource ListViewItemSelected}"/>
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="false">
                            <Setter Property="Foreground" Value="{StaticResource ListViewHeaderBackground}"/>
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource ListViewItemHover}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="BorderThickness" Value="0,1,0,0"/>
        <Setter Property="BorderBrush" Value="Red"/>
</Style>	
	
</ResourceDictionary>